home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The World of Computer Software
/
The World of Computer Software.iso
/
pcmagwin.zip
/
MEMCLEAR.ASM
< prev
next >
Wrap
Assembly Source File
|
1992-06-06
|
478b
|
29 lines
;MEMCLEAR.ASM - clears memory to any value
;
;Usage:
;
; CALL MemClear(BYVAL Segment%, BYVAL Address%, BYVAL NumBytes%, BYVAL Value%)
;
;or
;
; CALL MemClear(SEG Array(Start), BYVAL NumBytes%, BYVAL Value%)
;
;or
;
; CALL MemClear(SEG Variable, BYVAL NumBytes%, BYVAL Value%)
.Model Medium, Basic
.Code
MemClear Proc, Dest:DWord, NumBytes:Word, Value:Word
Les DI,Dest
Mov CX,NumBytes
Mov AX,Value
Rep Stosb
Ret
MemClear Endp
End